package com.sjhang.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.Version;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * 文章打赏表
 *
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class TbReward implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 打赏文章流水id
     */
    @TableId(value = "reward_id", type = IdType.ID_WORKER)
    private Long rewardId;

    /**
     * 文章id
     */
    private Long articleId;

    /**
     * 打赏人id
     */
    private Long userId;

    /**
     * 打赏金额
     */
    private BigDecimal rewardMoney;

    /**
     * 创建时间
     */
    private LocalDateTime createTime;

    /**
     * 最近更新时间
     */
    private LocalDateTime updateTime;

    /**
     * 逻辑删除
     */
    @TableLogic
    private Integer deleteFlag;

    /**
     * 版本号
     */
    @Version
    private Integer versionFlag;

}
